package com.np.shop.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.np.shop.entity.TbAdmin;
import com.np.shop.mapper.TbAdminMapper;
import com.np.shop.service.ITbAdminService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * <p>
 * 用户表 服务实现类
 * </p>
 *
 * @author 李高帅
 * @since 2020-11-26
 */
@Service
public class TbAdminServiceImpl extends ServiceImpl<TbAdminMapper, TbAdmin> implements ITbAdminService {
    @Resource
    private TbAdminMapper tbAdminMapper;
    @Override
    public TbAdmin findByUsernameAndPassword(TbAdmin tbAdmin) {
        return tbAdminMapper.findByUsernameAndPassword(tbAdmin);
    }


    @Override
    public void update(TbAdmin tbAdmin) {
        tbAdminMapper.updateById(tbAdmin);
    }
}
